package homework.test1
//定义一个double类型的列表，长度是8，求数组中所有数的积

object ProductOfList {
  def main(args: Array[String]): Unit = {
    val list = List(1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0)
    val num = list.reduce(_*_)
    println(num)

  }
}
